Package edu.uky.ai.lp.ai
Class LogicAgent
java.lang.Object
edu.uky.ai.lp.ai.LogicAgent
- All Implemented Interfaces:
Agent
public class LogicAgent extends java.lang.Object implements Agent
An artificially intelligent agent which uses logical reasoning based on
observations to decide which squares are safe to visit.
- Author:
- Your Name
-
Constructor Summary
Constructors Constructor Description LogicAgent()Creates a new logical agent. -
Method Summary
Modifier and Type Method Description ActionchooseAction(Game game)Chooses the next move for the player to make.voidobserve(Result result)Alerts the player to the result of the most recent action.
-
Constructor Details
-
LogicAgent
public LogicAgent()Creates a new logical agent.
-
-
Method Details
-
chooseAction
Description copied from interface:AgentChooses the next move for the player to make.- Specified by:
chooseActionin interfaceAgent- Parameters:
game- the current state of the game- Returns:
- the action the player should take
-
observe
Description copied from interface:AgentAlerts the player to the result of the most recent action.
-